From d0c7f9b2ad9d9d93d6eb02e6d8ae9a48ac36c9ad Mon Sep 17 00:00:00 2001 From: "emellor@ewan" Date: Mon, 10 Oct 2005 19:06:14 +0100 Subject: [PATCH] This patch fixes an error in the xm create path when the xc.domain_create call fails (eg, when ACM policy prevents creation of a domain). When xc.domain_create fails, dompath never gets set. Signed-off-by: Tom Lendacky --- tools/python/xen/xend/XendDomainInfo.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/python/xen/xend/XendDomainInfo.py b/tools/python/xen/xend/XendDomainInfo.py index c9711808a8..cc949d15e0 100644 --- a/tools/python/xen/xend/XendDomainInfo.py +++ b/tools/python/xen/xend/XendDomainInfo.py @@ -1087,7 +1087,8 @@ class XendDomainInfo: log.debug("XendDomainInfo.destroy: domid=%s", self.domid) self.cleanupVm() - self.destroyDomain() + if self.dompath is not None: + self.destroyDomain() def destroyDomain(self): -- 2.30.2